﻿using Microsoft.Reporting.WebForms;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;




namespace WebReports
{

    public partial class _Default : System.Web.UI.Page
    {
        protected void Page_Load(object sender, EventArgs e)
        {
            
            if (!IsPostBack)
            {
                RV1.ProcessingMode = Microsoft.Reporting.WebForms.ProcessingMode.Remote;
                RV1.ShowCredentialPrompts = true;
                ReportServerCredentials rpCredential = new ReportServerCredentials();
                RV1.ServerReport.ReportServerCredentials = rpCredential;
                RV1.ServerReport.ReportServerUrl = new Uri("http://61.155.174.99:9200/ReportServer");
                RV1.ServerReport.ReportPath = "/JSTTReport/WEBReport/r3_1";
                ReportParameter[] p = new ReportParameter[4];
                p[0] = new ReportParameter("year", "2015");
                p[1] = new ReportParameter("month", "07");
                p[2] = new ReportParameter("day", "25");
                p[3] = new ReportParameter("devtype", "3");
               // RV1.ServerReport.SetParameters(p);
                //RV1.LocalReport.SetParameters(p);
                RV1.ShowParameterPrompts = false;
                RV1.ServerReport.Refresh();
            }
        }

        protected void Calendar1_SelectionChanged(object sender, EventArgs e)
        {

        }
    }
}